<html>
<head></head>
<body>
{{extends file = '../../layout.html'}} {{block name = content}}
<div class="row">
    <div class="col-xs-12">
        <h3 class="header smaller lighter blue">文章列表</h3>
        <div class="table-header">
            所有文章-的列表
        </div>
        <div class="table-responsive">
            <table id="sample-table-2" class="table table-striped table-bordered table-hover">
                <thead>
                <tr>
                    <th class="center"> <label> <input type="checkbox" class="ace" /> <span class="lbl"></span> </label> </th>
                    <th>标题</th>
                    <th>作者</th>
                    <th class="hidden-480">发布时间</th>
                    <th class="hidden-480">分类</th>
                    <th> <i class="icon-time bigger-110 hidden-480"></i> 摘要 </th>
                    <th class="hidden-480">状态</th>
                    <th></th>
                </tr>
                </thead>
                <tbody>
                {{foreach from=$list item=ls}}
                <tr class="post-{{$ls.id}}" id="row-{{$ls.id}}">
                    <td class="center"> <label> <input type="checkbox" class="ace" /> <span class="lbl"></span> </label> </td>
                    <td> <a href="/post/{{$ls.id}}">{{$ls.title}}</a> </td>
                    <td>{{$ls.author}}</td>
                    <td class="hidden-480">{{$ls.publish_time}}</td>
                    <td class="hidden-480">{{$ls.category}}</td>
                    <td>{{$ls.summary}}</td>
                    <td class="hidden-480"> <span class="label label-sm label-warning">{{$ls.status}}</span> </td>
                    <td>
                        <div class="visible-md visible-lg hidden-sm hidden-xs action-buttons">
                            <a class="blue" href="#"> <i class="icon-zoom-in bigger-130"></i> </a>
                            <a class="green" href="/admin?p=post&amp;a=m&amp;id={{$ls.id}}"> <i class="icon-pencil bigger-130"></i> </a>
                            <a class="red a-delete" href="javascript:;" data-id="{{$ls.id}}"> <i class="icon-trash bigger-130"></i> </a>
                        </div>
                        <div class="visible-xs visible-sm hidden-md hidden-lg">
                            <div class="inline position-relative">
                                <button class="btn btn-minier btn-yellow dropdown-toggle" data-toggle="dropdown"> <i class="icon-caret-down icon-only bigger-120"></i>
                                    <ul class="dropdown-menu dropdown-only-icon dropdown-yellow pull-right dropdown-caret dropdown-close">
                                        <li> <a href="#" class="tooltip-info" data-rel="tooltip" title="View"> <span class="blue"> <i class="icon-zoom-in bigger-120"></i> </span> </a> </li>
                                        <li> <a href="#" class="tooltip-success" data-rel="tooltip" title="Edit"> <span class="green"> <i class="icon-edit bigger-120"></i> </span> </a> </li>
                                        <li> <a href="#" class="tooltip-error" data-rel="tooltip" title="Delete"> <span class="red"> <i class="icon-trash bigger-120"></i> </span> </a> </li>
                                    </ul> </button>
                            </div>
                        </div> </td>
                </tr> {{/foreach}}



                <div id="aw-ajax-box"></div>
                <script>
                    $(function () {
                        $(".red.a-delete").click(function () {
                            JET.delete($(this).attr('data-id'),'post');
                            //JET.alert('警告');
                           /* JET.dialog('publish',{},function(){
                                alert('dd');
                            })*/
                        });
                    })
                </script>
                </tbody>
            </table>
        </div>
    </div>
</div> {{/block}}
</body>
</html>